package com.example.springbootdemo.enums;

public enum ResultEnum {

    FAILES(1, "请求失败"),
    SUCCESS(0, "请求成功"),
    UNKONW_ERROR(-1, "未知错误"),
    ERROR_PASSWORD(-2, "密码错误"),
    NO_ACCOUNT(-3, "账号不存在"),
    TOKEN_OUT_TIME(401, "请重新登录");

    private Integer code;
    private String message;

    ResultEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
